package cn.zyb.system.domain;

import java.util.ArrayList;
import java.util.List;

import cn.zyb.basic.domain.BaseDomain;
import cn.zyb.org.domain.Department;
import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.Data;

/**
 * 实体类：
 */
@Data
public class Menu extends BaseDomain{

  private String name;
  private String component;
  private String url;
  private String icon;
  private Integer index;
  private Long parentId;
  private Menu parent;
  private String intro;
  private Boolean state;

  //用于装当前菜单的子菜单
  //菜单树最后一级没有数据就不显示
  @JsonInclude(JsonInclude.Include.NON_EMPTY)
  private List<Menu> children = new ArrayList<>();

  public List<Menu> getChildren() {
    return children;
  }



}
